import { ApiProperty, ApiPropertyOptional } from '@nestjs/swagger';
import { IsOptional, IsString } from 'class-validator';

export class ModelEntity {
  id: string;
  @ApiProperty({
    description: '型号名称',
    default: null,
  })
  @IsString()
  name: string;
  @ApiProperty({
    description: '型号编码',
    default: null,
  })
  @IsString()
  code: string;
  @ApiPropertyOptional({
    description: '型号描述',
    default: null,
  })
  @IsString()
  @IsOptional()
  description?: string;
  isDelete: boolean;
}
